function request(url,method="GET",data,callback) {
  wx.request({
    url: url,
    data: data,
    header: {},
    method: method,
    dataType: 'json',
    responseType: 'text',
    success: function (res) {
      callback(res);
     },
    fail: function (res) { callback(res); },
    complete: function (res) { },
  })
}

module.exports = {
  request:request
};